package net.e4net.watrix.example.action.login;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import net.e4net.watrix.ActionResponse;
import net.e4net.watrix.WatrixContext;
import net.e4net.watrix.WatrixException;
import net.e4net.watrix.example.base.ExamConstants;
import net.e4net.watrix.runtime.AbstractAction;

public class LogoutActn extends AbstractAction {

	public ActionResponse execute(WatrixContext context,
			HttpServletRequest request, HttpServletResponse response)
			throws IOException, ServletException, WatrixException {

		request.getSession().removeAttribute(ExamConstants.SESSION_USER);
		
		return super.getActionResponse(context);
	}

}